package com.grep.web;

import java.util.List;

import com.grep.extra.dao.WebSiteDao;
import com.grep.extra.dao.impl.TaskDAOSQL;
import com.grep.extra.dao.impl.WebSiteDAOSQL;
import com.grep.extra.factory.data.impl.SiteUrl;
import com.grep.extra.factory.data.impl.TaskUrl;

/**
 * @author yuyue z_yuguangyue@boco.com.cn
 * 
 * version <br>
 * Copyright (C) for index page .
 * <br>
 *
 * Description: .
 * 
 *
 * CreateTime: Feb 13, 2012  10:06:02 PM
 *
 * Change History:
 *
 *        Date             CR Number              Name              Description of change
 *
 *
 */
public class IndexService {
	
	//返回所有的网站信息
	public List<SiteUrl> getAllSites(){ 
		WebSiteDao siteDao = new WebSiteDAOSQL(); 
		return siteDao.getSiteUrls(); 
	} 
	
	public List<TaskUrl> getTaskNames(String sitename){
		TaskDAOSQL taskDaoSql = new TaskDAOSQL();
		return taskDaoSql.getTaskNamesbySiteName(sitename);
	}
 
}
